Database Handicapping Software- JCapper

JCapper Message Board

          JCapper 101
                      -- Exporting Factors from Starterhistory

Home Register
Log In
By Exporting Factors from Starterhistory
dogger67
7/10/2017
8:09:47 AM
How do I export for Claiming Sprint races at a track when I only want to see MLine and a few other factors in an excel file for regression. Obviously need Officialfinishpostion but how is the UDM structured for track and distance specifics? I see examples for Starterstoday but none for Starterhistory.

~Edited by: dogger67  on:  7/10/2017  at:  8:09:47 AM~

Reply
dogger67
7/10/2017
5:13:53 PM
I found what I was looking for in my earlier question.

Reply
jeff
7/11/2017
12:10:30 PM
I didn't see this thread until just now. (Sorry about that.)

Glad you found the info you were looking for.

For benefit of those looking for info about controlling the columns, rows, and row sorting for .csv files exported by the JCX File Exports Module to your hard drive -- the info can be found in the JCX File Exports Module Help Doc:
http://www.jcapper.com/helpDocs/JCXFileExportModule.html


--quote:
"Selected Columns:

The sql expression that I used in the above example uses "SELECT * FROM STARTERHISTORY" (without the quotes.)

Using the * or wildcard character in this manner causes the .CSV file generated by an export to include every column in the table.

When you want the .CSV file generated by an export to contain every column in the table:

Use the * or wildcard character like I did in the above example.

But when you want the .CSV file generated by an export to only contain selected columns:

Change your sql expression. Reference only the column names you want in the .CSV file created by the Export.

For example, if the following sql expression were used to generate an export:

"SELECT [DATE], TRACK, RACE, HORSENAME, ODDS FROM STARTERHISTORY" (without the quotes.)

The resulting .CSV file generated by the export will contain only the following selected columns:

DATE, TRACK, RACE, HORSENAME, and ODDS.

What if you want to make the columns in the .CSV file created by an Export appear in a specific order? For example:

ODDS, HORSENAME, DATE, TRACK, RACE

Simply change the order in which the column names are referenced in your sql expression - like this:

"SELECT ODDS, HORSENAME, [DATE], TRACK, RACE FROM STARTERHISTORY" (without the quotes.)



Selected Rows:

In the above sql expression, I used the following WHERE clause:


WHERE track='aqu'
and intsurface = 2
and dist = 1320
and not startslifetime = 0

and [DATE] >= #01-01-2015#
and [DATE] <= #12-31-2015#


The factor constraints after the WHERE keyword, in this case track, intsurface, dist, startslifetime, and [DATE], control the rows that are written to the .CSV file by the Export.

Change the expression text after the WHERE keyword to change the rows that appear in a .CSV file created by an Export.


Row Sorting:

In the above sql expression, I used the following ORDER BY clause:


ORDER BY [DATE], val(RACE)


The field names after the ORDER BY keyword, in this case [DATE], val(RACE), control the order in which the rows within a .CSV file created by an Export are sorted.

Change the expression text after the ORDER BY keyword to change the sort order for the rows within a .CSV file created by an Export.


These behaviors apply to all Exports generated by the JCX File Exports Module."
--end quote




-jp

.








Reply
Reply

Copyright © 2018 JCapper Software              back to the JCapper Message Board              www.JCapper.com